﻿@{
    string dir = "~/Content/Music/Optimised/";
    string[] songs = new string[] {
        "01. Jose Padilla - Bosaxi.ogg",
        "Nina Simone - Sinnerman (THE BEST VERSION).ogg",
        "02. Coldplay - Trouble.ogg",
        "03. Moby - In this world.ogg",
        "06-nightmares_on_wax--you_wish-aes.ogg",
        "05. Eroc - Wolkenreise.ogg",
        "09. Gabriela Anders - Fire of Love.ogg",
        "101-cecile_bredie_-_the_autumn_leaves_les_feuilles_mortes-mst.ogg",
        "16. Rose Royce - Wishing on a Star.ogg"
                    
                    
                    
    };
    Random rand = new Random(DateTime.Now.Second);
    int i = rand.Next(0, (songs.Length - 1));
    string Path = dir + songs[i];
    string absolutePath = Url.Content(Path);
    
    }

<div>
    <audio preload="auto" controls="controls" autoplay="autoplay" src="@Url.Content(absolutePath)">
    Your browser does not support the audio element.
    </audio>
</div>